package Action;

import PO.CutOffDatePage;
import PO.GuYongPage;
import com.epwk.action.Action;
import com.epwk.action.JSExecutor;
import com.epwk.driver.SeleniumDriver;
import com.epwk.logger.LoggerControler;
import com.epwk.tools.DateFormat;
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.Test;
import Action.*;

/**
 * Created by Administrator on 2016/11/22.
 */
public class GuYong {

    final static LoggerControler log= LoggerControler.getLogger(GuYong.class);

    public static void guyong(int cash,int day) throws InterruptedException {

//        滚动滚动条
        JSExecutor.jsExecutor("var q=document.documentElement.scrollTop=800");

//        雇佣任务金额
        Action.click(GuYongPage.model_tb);
        Action.click(GuYongPage.guyong);
        Action.sendkeys(GuYongPage.cash_gy, String.valueOf(cash));

//        截止时间
//        CutOffDate.cutOffDate(day,type);
        Action.clear(CutOffDatePage.CutOffDate);
        Action.sendkeys(CutOffDatePage.CutOffDate,DateFormat.beforeORLateDate(day,DateFormat.COMMON_DATE_FORMAT));


    }

}
